//package com.yc.cloud.portal.controller;
//
//import com.yc.cloud.common.basic.api.ResponseResult;
//import com.yc.cloud.common.basic.dto.BaseQueryParam;
//import com.yc.cloud.common.orm.CommonPage;
//import com.yc.cloud.entity.DeviceGpsLogs;
//import com.yc.cloud.portal.service.DeviceGpsLogsService;
//import io.swagger.annotations.Api;
//import io.swagger.annotations.ApiOperation;
//import io.swagger.annotations.ApiParam;
//import jakarta.annotation.Resource;
//import lombok.val;
//import org.springframework.validation.annotation.Validated;
//import org.springframework.web.bind.annotation.*;
//
//
///**
// * GPS日志
// *
// * @author Yancy
// * @date 2024-11-26
// */
//@RestController
//@RequestMapping("/device-gps-logs")
//@Api(value = "GPS日志", tags = "GPS日志")
//public class DeviceGpsLogsController {
//
//    @Resource
//    private DeviceGpsLogsService deviceGpsLogsService;
//
//
//    @GetMapping
//    @ApiOperation(value = "GPS日志列表", notes = "支持分页查询,字段模糊匹配,排序等")
//    public ResponseResult<CommonPage<DeviceGpsLogs>> list(@Validated BaseQueryParam param) {
//        val result = deviceGpsLogsService.list(param);
//        return ResponseResult.success(CommonPage.restPage(result));
//    }
//
//
//    @GetMapping("{id}")
//    @ApiOperation(value = "GPS日志详情", notes = "根据ID查询")
//    public ResponseResult<DeviceGpsLogs> get(@PathVariable @ApiParam(value = "ID", required = true) Long id) {
//        val result = deviceGpsLogsService.get(id);
//        return ResponseResult.success(result);
//    }
//
//
//    @PostMapping
//    @ApiOperation(value = "添加GPS日志", notes = "添加")
//    public ResponseResult<DeviceGpsLogs> create(@Validated @RequestBody DeviceGpsLogs param) {
//        val result = deviceGpsLogsService.create(param);
//        return result != null ? ResponseResult.success(result) : ResponseResult.failed();
//    }
//
//
//    @ApiOperation(value = "删除GPS日志", notes = "通过ID删除")
//    @DeleteMapping(value = "{id}")
//    public ResponseResult<Boolean> delete(@PathVariable @ApiParam(value = "ID", required = true) Long id) {
//        val result = deviceGpsLogsService.delete(id);
//        return result ? ResponseResult.success(true) : ResponseResult.failed();
//    }
//
//
//    @ApiOperation(value = "修改GPS日志", notes = "通过ID修改")
//    @PutMapping(value = "{id}")
//    public ResponseResult<DeviceGpsLogs> update(@PathVariable @ApiParam(value = "ID", required = true) Long id, @Validated @RequestBody DeviceGpsLogs param) {
//        val result = deviceGpsLogsService.update(id, param);
//        return result != null ? ResponseResult.success(result) : ResponseResult.failed();
//    }
//}
